Repository navigation
poly: run Laguna S 2.1 (llama.cpp architecture laguna) - #166
Merged
Merged
Conversation
- src/poly/laguna.{hpp,cpp}: the model, on flint.cpp's pattern (3 of 4 layers
sliding-window, sigmoid-routed experts). New: per-layer head counts, YaRN on
the full layers, a softplus output gate, no sinks.
- kernels: head_norm_rope_yarn() as a second instantiation of
head_norm_rope_kernel (the first is unchanged), and mul_softplus().
- engine.cpp: the factory entry (not on Metal) and laguna in the --kv q8_0 gate.
- CMakeLists.txt: laguna.cpp in the three targets that list the models.
- docs/Q8_KV.md: laguna in the list of models.
This was referenced Nov 15, 2026
Collaborator
|
I merged it with one small fix, its now in v0.2.19-poly.1. I couldn't run it with the real laguna weights here. Thanks |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Title
Issue: #16 (the model vote)
Summary
strata-poly runs poolside's Laguna S 2.1 (118B-A8B) GGUFs. The model code follows
flint.cpp, which has the same3-of-4 sliding-window layout and sigmoid routing:
git diff --no-index src/poly/flint.cpp src/poly/laguna.cppis 20hunks. Other models are unaffected. The chat format is a separate PR (#167), and so is a faster decode kernel.
What changed
src/poly/laguna.{hpp,cpp}(new): the model. Unlike Flint: query heads per layer (48 full, 72 window), YaRN onthe full layers, a softplus output gate, no attention sinks.
src/poly/kernels.cu,include/strata/poly/kernels.hpp:head_norm_rope_yarn(), ashead_norm_rope_kernel<true>.The
<false>instantiation is the old kernel body unchanged. Alsomul_softplus().src/poly/engine.cpp: the factory entry (not on Metal), andlagunain the--kv q8_0gate.CMakeLists.txt:laguna.cppin the three targets that list the models.docs/Q8_KV.md:lagunain the list of models.How it was checked
2× RTX 5060 Ti 16 GB, i9-9900K, 128 GB DDR4-3200, Linux, CUDA 13.4 (driver 580.196.07);
Laguna-S-2.1-UD-Q3_K_XL(Unsloth).Against llama.cpp (build 12242, same file, greedy): strata-poly follows llama.cpp's answer and its 10 likeliest
tokens are compared at each step. 4 prompts of 6 to 2,410 tokens, 64 steps each.
For scale, strata-poly's own q8_0 and fp16 runs differ by as much: 95.3% same top token, KL median 2.3e-3.
Default path unchanged:
cuobjdump -sass: all 2,559 kernels of main'sstrata-polyare in this build with the same machine code.head_norm_rope_kernelis now namedhead_norm_rope_kernel<false>, with the same instructions.poly_attend_testandpoly_sink_attend_testprint the same output as on main.lagunaadded to the--kv q8_0refusal message.Builds: CUDA sm_120; HIP gfx1100 (ROCm 7.2.4,
rocm/dev-ubuntu-24.04:7.2.4-completein Docker).NOT STRATA_HIP_GFX906), and it compilesnone of these files.
#if. Metal compileskernels.hpp, whichonly gains declarations; nothing on Metal calls them.
Extra Notes
--kv q8_0: 35 tok/s at 2K of context, 8.9 at 196K. The decode PR addresses thelong-context number.